// 引入 react 依赖
import React, { Component } from 'react';
import { connect } from 'react-redux';
import { Text, View, Image, TouchableOpacity, ImageBackground, ScrollView, InteractionManager } from 'react-native';

// 引入第三方依赖
import _ from 'lodash';
import pureRender from 'pure-render-decorator';
import { Actions } from 'react-native-router-flux';

// antd 按需加载
import { Tabs, Toast, WhiteSpace } from '@ant-design/react-native';

// 引入 处理数据 所需文件
import { } from './module/module.js'

// 引入样式
import Style from './style/style.js';

// 引入公用组件
import { Status, NavBar, ScrollableTabBar, Good, CategoriesGoods } from '../../components/index.js'
import { CategoryGood, List } from '../Mall/components/index.js'


// 引入专用组件
import { } from './components'

// 引入工具包
import { press, size, ScreenWidth, ScreenHeight, defaultDataList, onEndReached, onRefresh, concatDataList, defaultPage } from '../../util/utils.js'
class Categories extends Component {

  constructor(props) {
    super(props);
    this.state = {
      offset: [],
      active: 0,
      scrollTop: 0
    };
  }

  componentDidMount() {

  }

  render() {
    const { categoryList } = this.props
    return (
      <View style={Style.container}>
        <Status />
        <NavBar
          title="商品分类"
          back={true}
        />
        <CategoriesGoods categoryList={categoryList} />
      </View >
    );
  }
}


export default connect(({ user, categoryList }) => ({
  user, categoryList
}))(pureRender(Categories))
